//
//  ViewController.m
//  location
//
//  Created by 美食家 on 16/8/2.
//  Copyright © 2016年 不孤独的美食家. All rights reserved.
//

#import "ViewController.h"
#import "LH_CLLocationManager.h"
@interface ViewController ()

@end

@implementation ViewController

- (void)viewDidLoad {
    [super viewDidLoad];
    self.view.backgroundColor=[UIColor greenColor];
    LH_CLLocationManager* manger=[LH_CLLocationManager shareLocation];
    
    [manger lh_getCurrentCity:^(NSString *cityString) {
        NSLog(@"当前城市:%@",cityString);
    }];
    [manger lh_getCurrentCountry:^(NSString *countryString) {
        NSLog(@"当前国家:%@",countryString);
    }];
    [manger lh_getCurrentProvince:^(NSString *provinceString) {
        NSLog(@"当前省份:%@",provinceString);
    }];
    [manger lh_getCurrentThoroughfare:^(NSString *thoroughfareString) {
        NSLog(@"当前街道:%@",thoroughfareString);
    }];
    [manger lh_getCurrentDetailAddress:^(NSString *detailAddressString) {
        NSLog(@"当前详细地址:%@",detailAddressString);
    }];
    [manger lh_getCurrentPostalCode:^(NSString *postalCodeString) {
        NSLog(@"当前邮政编码:%@",postalCodeString);
    }];
    [manger lh_getCurrentLocationCoordinate:^(CLLocationCoordinate2D locationCorrrdinate) {
        NSLog(@"当前位置经纬度(%lf,%lf)",locationCorrrdinate.latitude,locationCorrrdinate.longitude);
    }];
    [manger lh_getCurrentLocationCoordinate:^(CLLocationCoordinate2D locationCorrrdinate) {
        NSLog(@"======当前位置经纬度(%lf,%lf)",locationCorrrdinate.latitude,locationCorrrdinate.longitude);
    } withAddress:^(NSString *detailAddressString) {
        NSLog(@"------当前详细地址:%@",detailAddressString);
    }];

}



@end
